//
//  RecommendedViewCell.m
//  BeautifulWardrobe
//
//  Created by mac on 16/7/30.
//  Copyright © 2016年 rongshao. All rights reserved.
//

#import "RecommendedViewCell.h"

@implementation RecommendedViewCell

- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self)
    {
        self.Img = [[UIImageView alloc] initWithFrame:CGRectMake(7, 0, WIDTH/2 - 20, WIDTH/2-20)];
        [self addSubview:self.Img];
        
        self.introduceLabel = [[UILabel alloc] initWithFrame:CGRectMake(10, CGRectGetMaxY(self.Img.frame)+5, CGRectGetWidth(self.Img.frame)-10, 40)];
        self.introduceLabel.numberOfLines = 2;
        self.introduceLabel.font = [UIFont systemFontOfSize:15];
        [self addSubview:self.introduceLabel];
        
        self.priceLabel = [[UILabel alloc] initWithFrame:CGRectMake(10, CGRectGetMaxY(self.introduceLabel.frame)+5, 80, 20)];
        self.priceLabel.textColor = [UIColor redColor];
        self.priceLabel.font = [UIFont systemFontOfSize:15];
        [self addSubview:self.priceLabel];
        
        self.numberLabel = [[UILabel alloc] initWithFrame:CGRectMake(self.frame.size.width-80, CGRectGetMaxY(self.introduceLabel.frame)+5, 25, 15)];
        self.numberLabel.font = [UIFont systemFontOfSize:10];
        self.numberLabel.textColor = [UIColor redColor];
        [self addSubview:self.numberLabel];
        
        UILabel *label = [[UILabel alloc] initWithFrame:CGRectMake(CGRectGetMaxX(_numberLabel.frame)-3, CGRectGetMaxY(self.introduceLabel.frame)+5, 40, 15)];
        label.font = [UIFont systemFontOfSize:10];
        label.text = @"件已售";
        [self addSubview:label];
    }
    return self;
}

@end
